package com.mjk.service.system;

import java.util.List;

import org.springframework.stereotype.Service;

import com.mjk.common.biz.BaseBiz;
import com.mjk.mapper.system.ElementMapper;
import com.mjk.model.system.Element;
import com.mjk.vo.PermissionInfo;

@Service
public class ElementService extends BaseBiz<ElementMapper, Element>{
	
	public List<Element> getAuthorityElementByUserId(String userId){
       return mapper.selectAuthorityElementByUserId(userId);
    }
	
    public List<Element> getAuthorityElementByUserId(String userId,String menuId){
        return mapper.selectAuthorityMenuElementByUserId(userId,menuId);
    }

    public PermissionInfo getPermissionByUriAndMethod(String uri, String method){
		return mapper.getPermissionByUriAndMethod(uri, method);
	}
}
